//
//  UIColor+RGB.m
//  Weibo29
//
//  Created by 曾静 on 16/6/29.
//  Copyright © 2016年 qq. All rights reserved.
//

#import "UIColor+RGB.h"

@implementation UIColor (RGB)
+(UIColor *)RGBWithRed:(CGFloat)red andGreen:(CGFloat)green andBlue:(CGFloat)blue{
    return  [UIColor colorWithRed:red/255.0 green:green/255.0 blue:blue/255.0 alpha:1];
}
+(UIColor *)randColor{
    CGFloat r = random()%256;
    CGFloat g = random()%256;
    CGFloat b = random()%256;
    return [self RGBWithRed:r andGreen:g andBlue:b];
}
@end
